<p>
  <b>Name:</b>
  <%=h company.name %>
</p>

<p>
  <b>Num siret:</b>
  <%=h company.num_siret %>
</p>

<p>
  <b>Phone num:</b>
  <%=h company.phone_num %>
</p>

<p>
  <b>Address:</b>
  <%=h company.address %>
</p>
<%= image_tag "http://maps.google.com/maps/api/staticmap?size=255x255&maptype=roadmap&sensor=false&markers=color:red|label:A|#{company.address}", :alt => "Google Map"%>

<p>
<h2>Rooms:</h2>
<table>
  <tr class="ui-state-default">
    <th>Code</th>
	<th>Stock</th>
	<th>Capacity</th>
  </tr>
  <% company.rooms.each do |room| %>
  <tr>
  	<td><%= link_to room.code, room %></td>
	<td><%=h room.stock %></td>
	<td><%=h room.capacity %></td>
  </tr>
  <%end%>
</table>
</p>
<p>
<h2>Contacts:</h2>
<table>
  <tr class="ui-state-default">
    <th>Name</th>
    <th>Firstname</th>
    <th>User</th>
    <th>Mail</th>
    <th>Phone num</th>
  </tr>
  <% company.contacts.each do |contact| %>
  <tr>
    <td><%=link_to contact.name, contact %></td>
    <td><%=h contact.firstname %></td>
    <td><%if contact.user != nil%><%=h contact.user.login %><%end%></td>
    <td><%=h contact.mail %></td>
    <td><%=h contact.phone_num %></td>
  </tr>
  <%end%>
</table>
</p>